<!doctype html>
<html lang="en">
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta name="description" content="coinfaces">

        <title>解释VS编译</title>

    <link rel="stylesheet" href="../../theme/css/style.css">
    <link rel="stylesheet" href="../../theme/css/pygments.css">



</head>

<body>
    <div class="content">
<h1>解释VS编译</h1>    <p>
        under
            <a href="../../tags/programming/">programming</a>
            <a href="../../tags/reading/">reading</a>
    </p>
    <p>
        in <a href="../../categories/tech/">tech</a>
    </p>
    <p>Published: 2016-09-28</p>


    <p>重温<a class="reference external" href="http://stackoverflow.com/questions/745743/is-python-interpreted-like-javascript-or-php">StackOverflow上一篇关于解释和编译的文章</a>，依然大受启发，这两个概念之间的界限并不是像教科书上说的那么清楚，中间有大片的灰色地带。</p>
<ul class="simple">
<li>纯解释（基本上只有Shell）</li>
<li>先符号化，然后解释（如很多版本的BASIC）</li>
<li>编译成字节码在虚拟机执行（如Java、C#、Python）</li>
<li>字节码+JIT，一边执行一边把字节码编译成机器码（如最近版本的Java、C#）</li>
<li>编译成目标机器代码，但仍有些机器代码不是硬件直接执行，而是用microcode实现并解释执行</li>
</ul>
<p>（完）</p>

    </div>
<nav class="nav sidebar">
    <div class="siteinfo">
        <div class="sitename"><a href="../..">coinfaces</a></div>
        <div class="tagline">Another Side of Life</div>
    </div>

        <a href="../../categories/">categories</a>
        <a href="../..">&larr; Home</a>
</nav><footer class="footer">
    <span>
        &copy; jpli &middot;
        under <a rel="license" href="http://creativecommons.org/licenses/by-sa/4.0/">CC-BY-SA 4.0</a>
    </span>
    |
    <span>
        Powered by:
        <a href="http://blog.getpelican.com/">Pelican</a>
    </span>
</footer></body>
</html>